﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.ComponentModel;

namespace TvTipper.Entities
{
    public class RankableEntity : Entity, INotifyPropertyChanged
    {
        private int? m_userRank;

        public int? UserRank
        {
            get { return m_userRank; }
            set
            {
                if (m_userRank != value)
                {
                    m_userRank = value;
                    NotifyPropertyChanged("UserRank");
                }
            }
        }

        public virtual float? OverRank { get; protected internal set; }

        public virtual string Website { get; protected internal set; }
        public virtual string WikiUrl { get; protected internal set; }

        public event PropertyChangedEventHandler PropertyChanged;
        protected void NotifyPropertyChanged(String propertyName = "")
        {
            if (PropertyChanged != null)
            {
                PropertyChanged(this, new PropertyChangedEventArgs(propertyName));
            }
        }
    }
}
